package com.wgts.wgts.dagger.module;

import com.wgts.wgts.dagger.scope.ActivityScope;
import com.wgts.wgts.mvp.model.IWgtsNomalMarketActivityModel;
import com.wgts.wgts.mvp.model.IWgtsProductModel;
import com.wgts.wgts.mvp.model.imp.WgtsNomalMarketActivityModel;
import com.wgts.wgts.mvp.model.imp.WgtsProductModel;
import com.wgts.wgts.mvp.presenter.IWgtsNomalMarketActivityPresenter;
import com.wgts.wgts.mvp.presenter.imp.WgtsNomalMarketActivityPresenter;
import com.wgts.wgts.mvp.view.IWgtsNomalMarketActivityView;
import com.wgts.wgts.mvp.view.IWgtsResetPasswordActivityView;
import com.wgts.wgts.netmodle.NetService;

import dagger.Module;
import dagger.Provides;

@Module
public class WgtsNomalMarketActivityModule {
    private IWgtsNomalMarketActivityView view;

    public WgtsNomalMarketActivityModule(IWgtsNomalMarketActivityView view) {
        this.view = view;
    }

    @Provides
    @ActivityScope
    public IWgtsNomalMarketActivityView provideView(){
        return view;
    }

    @Provides
    @ActivityScope
    public IWgtsNomalMarketActivityModel provideModel(NetService netService){
        return new WgtsNomalMarketActivityModel(netService);
    }

    @Provides
    @ActivityScope
    public IWgtsProductModel provideProductModel(NetService netService){
        return new WgtsProductModel(netService);
    }

    @Provides
    @ActivityScope
    public IWgtsNomalMarketActivityPresenter providePresenter(IWgtsProductModel model, IWgtsNomalMarketActivityModel marketActivityModel, IWgtsNomalMarketActivityView view){
        return new WgtsNomalMarketActivityPresenter(marketActivityModel, view, model);
    }

}
